-- GENERATED SPELL FOR [Crystal Handler] --


function spell0_26627(pUnit, Event) --@Flash of Darkness,n/a--
pUnit:FullCastSpellOnTarget(49668,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_26627', 1000, 1)
end

function spell1_26627(pUnit, Event) --@Flash of Darkness,n/a--
pUnit:FullCastSpellOnTarget(59004,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_26627', 1000, 1)
end

function Sorts_26627(pUnit, Event)
local choix_sorts_26627 = math.random(0, 1)
if choix_sorts_26627 == 0 then
pUnit:RegisterEvent('spell0_26627', 1, 1)
end
if choix_sorts_26627 == 1 then
pUnit:RegisterEvent('spell1_26627', 1, 1)
end
end

function mob26627_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_26627', math.random(1500, 3000), 1)
end

function mob26627_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob26627_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob26627_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(26627, 1, 'mob26627_Action')
RegisterUnitEvent(26627, 2, 'mob26627_Leave')
RegisterUnitEvent(26627, 3, 'mob26627_Kill')
RegisterUnitEvent(26627, 4, 'mob26627_Die')
